/* Parser.java
 * 
 * Alfred Olschnoegger
 * 26.05.2008
 */

package application.parser;

import java.util.Collection;

import application.GameInfoProvider;
import application.ServerInfoProvider;

import domain.GameObject;
import domain.Hunter;
import domain.game.Game;
import exceptions.RabbitBusterException;

/**
 * Abstract parser class.
 * Tranforms the given field data into a specific format.
 * The format is specified by the inherited class.
 *
 * @date 26.05.2008
 * @author Alfred Olschnoegger
 */

public abstract class  Parser<T> {
	
	
	/**
	 * Adds a GameObject to the Parsed String
	 * 
	 * @param obj object which should be added
	 */
	public abstract void add(GameObject obj);	
	
	/**
	 * adds a hunter to the parsed string
	 * 
	 * @param hunter hunter which should be added
	 */
	public abstract void add(Hunter hunter);
	
	
	/**
	 * 
	 * @param ex exception which should be added
	 */
	public abstract void add(RabbitBusterException ex);
	
	
	/**
	 * 
	 * @param authKey authkey which should be added
	 */	
	public abstract void addAuth(long authKey);
	
	/**
	 * overwrites the whole parsed string with the success value
	 */
	public abstract void success();
	
	
	/**
	 * 
	 * @param prov
	 */
	public abstract void add(Game prov);

	public abstract void add(ServerInfoProvider serverInfoProvider);
	
}


// end of Parser.java
